﻿﻿using System;
using System.Text.RegularExpressions;

class ParseURL
{
    static void Main()
    {
        string uri = "http://www.devbg.org/forum/index.php";

        Console.WriteLine("[protocol] = \"{0}\" ", Regex.Match(uri, "(.*)://(.*?)(/.*)").Groups[1]);
        Console.WriteLine("[server] = \"{0}\" ", Regex.Match(uri, "(.*)://(.*?)(/.*)").Groups[2]);
        Console.WriteLine("[resource] = \"{0}\" ", Regex.Match(uri, "(.*)://(.*?)(/.*)").Groups[3]);



    }
}